<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="./vue.js"></script>
</head>
<body>
    <div id="app">
            数量<input type="text" v-model="num"><br>
            单价<input type="text" v-model="price"><br>
            总计:{{ num * price }}
</body>
<script>
    new Vue({
        el:'#app',
        data:{
            num:1,
            price:1
        }
    })
</script>
</html>